home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Visual Basic Controls
/
Visual Basic Controls.iso
/
vbcontrol
/
rprint_1
/
gridinpu.frm
next >
Wrap
Text File
|
1999-05-30
|
13KB
|
444 lines
VERSION 5.00
Object = "{5E9E78A0-531B-11CF-91F6-C2863C385E30}#1.0#0"; "MSFLXGRD.OCX"
Begin VB.Form Formiga
BackColor = &H00FFFFFF&
Caption = "Grid "
ClientHeight = 8460
ClientLeft = -105
ClientTop = 2355
ClientWidth = 11205
LinkTopic = "Form1"
MDIChild = -1 'True
ScaleHeight = 8460
ScaleWidth = 11205
WindowState = 2 'Maximized
Begin VB.Frame Frame2
BackColor = &H00FFFFFF&
BorderStyle = 0 'None
Height = 2295
Left = 165
TabIndex = 3
Top = -150
Width = 9855
Begin VB.TextBox Invoice
Appearance = 0 'Flat
Height = 285
Left = 6090
TabIndex = 11
Text = "Invoice"
Top = 720
Width = 1215
End
Begin VB.TextBox Country
Appearance = 0 'Flat
Height = 375
Left = 6120
TabIndex = 9
Text = "Country"
Top = 1680
Width = 2775
End
Begin VB.TextBox CustAddress
Appearance = 0 'Flat
Height = 375
Left = 6090
TabIndex = 8
Text = "CustAddress"
Top = 1080
Width = 2775
End
Begin VB.TextBox Date
Appearance = 0 'Flat
Height = 375
Left = 6090
TabIndex = 7
Text = "Date"
Top = 300
Width = 1935
End
Begin VB.TextBox City
Appearance = 0 'Flat
Height = 375
Left = 3480
TabIndex = 6
Text = "City"
Top = 1680
Width = 2580
End
Begin VB.TextBox CustomerName
Appearance = 0 'Flat
Height = 405
Left = 3480
TabIndex = 4
Text = "CustomerName"
Top = 1080
Width = 2565
End
Begin VB.Label Label3
Alignment = 2 'Center
BackStyle = 0 'Transparent
Caption = "MsFlexGrid Cell Edit Example"
BeginProperty Font
Name = "MS Sans Serif"
Size = 9.75
Charset = 177
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H00C00000&
Height = 375
Left = 15
TabIndex = 12
Tag = "noprint"
Top = 1800
Width = 3375
End
Begin VB.Image Image1
Height = 1335
Left = -15
Picture = "GridInput.frx":0000
Stretch = -1 'True
Top = 135
Width = 3000
End
Begin VB.Label Label2
BackStyle = 0 'Transparent
Caption = "Order"
Height = 255
Left = 5340
TabIndex = 10
Top = 720
Width = 615
End
Begin VB.Label Label1
BackStyle = 0 'Transparent
Caption = "Bill To"
Height = 255
Left = 3360
TabIndex = 5
Top = 720
Width = 615
End
End
Begin VB.Frame Frame1
BackColor = &H00FFFFFF&
BorderStyle = 0 'None
Height = 6255
Left = 225
TabIndex = 0
Top = 2175
Width = 9975
Begin VB.PictureBox inputpic
Appearance = 0 'Flat
BackColor = &H00FFFFFF&
ForeColor = &H80000008&
Height = 300
Left = 1080
ScaleHeight = 270
ScaleWidth = 795
TabIndex = 1
Tag = "noprint"
Top = 720
Visible = 0 'False
Width = 825
Begin VB.TextBox TMText
Appearance = 0 'Flat
BorderStyle = 0 'None
BeginProperty Font
Name = "MS Sans Serif"
Size = 9.75
Charset = 177
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 390
Left = 15
TabIndex = 2
ToolTipText = "Enter data"
Top = 0
Width = 840
End
End
Begin MSFlexGridLib.MSFlexGrid gridinv
Height = 4965
Left = 90
TabIndex = 15
Top = 180
Width = 10530
_ExtentX = 18574
_ExtentY = 8758
_Version = 393216
Rows = 25
Cols = 5
FixedCols = 0
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "MS Sans Serif"
Size = 9.75
Charset = 177
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
End
Begin VB.Label Total
Appearance = 0 'Flat
BackColor = &H80000005&
BackStyle = 0 'Transparent
BorderStyle = 1 'Fixed Single
Caption = "Total"
ForeColor = &H80000008&
Height = 255
Left = 7290
TabIndex = 14
Top = 5490
Width = 615
End
Begin VB.Label TotalInv
Alignment = 1 'Right Justify
BackStyle = 0 'Transparent
Height = 255
Left = 8025
TabIndex = 13
Top = 5505
Width = 1110
End
End
End
Attribute VB_Name = "Formiga"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Dim LastLine As Integer
Dim Edit As Boolean
Dim OldCol As Integer
Dim OldRow As Integer
Private Sub Form_Activate()
gridinv.Col = 0
TMText.SetFocus
End Sub
Private Sub Form_Load()
LastLine = 25
Setgrid
gridinv.Col = 1
End Sub
Private Sub gridinv_EnterCell()
Dim ResNo As Integer
On Error Resume Next
If Init Then Exit Sub
ResNo = 116
If gridinv.Col = 4 Then
gridinv.Col = OldCol
Exit Sub
End If
inputpic.Move gridinv.CellLeft - 20
inputpic.Top = gridinv.CellTop + gridinv.Top - 20
inputpic.Visible = True
inputpic.Width = gridinv.CellWidth + 10
inputpic.Height = gridinv.CellHeight + 20
TMText.Width = inputpic.Width
OldCol = gridinv.Col
OldRow = gridinv.Row
TMText.SetFocus
TMText.Text = gridinv.Text
TMText.SelStart = 0
TMText.SelLength = 100
OldCo